package zouran.shounewsspringboot.service;

import org.springframework.stereotype.Service;
import zouran.shounewsspringboot.entity.News;

import java.io.IOException;
import java.util.List;

/**
 * @author zouran
 * createDate：2023/5/31  17:32
 */
@Service
public interface NewsService {
    /**
     * @param author 作者名
     * @return 所有新闻
     */
    public List<News> getAllNewsByAuthor(String author);

    /**
     * @param url 文章地址
     * @return 是否添加成功
     */
    public boolean addWechatNews(String url) throws IOException;
    public int getAllCount();
}
